package org.budo.cmbc.direct.sdk.entity.ryb;

import org.budo.cmbc.direct.sdk.entity.AbstractCmbcDirectResponse;

import com.alibaba.fastjson.JSON;
import com.alibaba.fastjson.JSONObject;

import lombok.Getter;
import lombok.NoArgsConstructor;
import lombok.Setter;
import lombok.experimental.Accessors;

/**
 * 如意宝签约、解约
 */
@Getter
@Setter
@Accessors(chain = true)
@NoArgsConstructor
public class MELERybOpenCloseAccountResponse extends AbstractCmbcDirectResponse {
    private static final long serialVersionUID = -8271972032766766773L;
    /**
     * 基金交易账号
     */
    private String fundAcNo;

    public MELERybOpenCloseAccountResponse(String channelJnlNo, String responseJson) {
        super(channelJnlNo, responseJson);

        JSONObject jsonObj = JSON.parseObject(responseJson);

        this.fundAcNo = jsonObj.getString("FundAcNo");
    }
}
